
/*
7 avr. 2012 jblanchard 
*/

package com.jcb.countfrench.dao;

import java.util.ArrayList;
import java.util.List;

import com.jcb.countfrench.R;
import com.jcb.countfrench.model.BasicData;



public class ChineseDatabase {

	

public static void main(String args[]) {
	//exportData();
}


//public static List<DataChineseLanguage> loadData(String[][] chineseData) {
//	List<DataChineseLanguage> data = new ArrayList<DataChineseLanguage>();
//	for (int i = 0 ; chineseData != null && i < chineseData.length ; i++) {
//		DataChineseLanguage dat = new DataChineseLanguage(chineseData[i][0]);
//		data.add(dat);
//		dat.setId(i + "");
//		dat.setPinyin(chineseData[i][1]);
//		dat.setTranslated(chineseData[i][2]);
//		dat.setNumQuizz(chineseData[i][3]);
//		dat.setCarCompose(chineseData[i][4]);
//		dat.setCarComposeTraduit(chineseData[i][5]);
//		dat.setExemple(chineseData[i][6]);
//		dat.setExempleTraduit(chineseData[i][7]);
//		if ( chineseData[i][9].equals("1")) {
//			dat.setFirstLevel(true);
//		}
//		else {
//			dat.setFirstLevel(false);
//		}
//		dat.setAdrImgage(chineseData[i][13]);
//		//dat.setAdrSon(chineseData[i][14]);
//	}
//	return data ;
//}

//public static List<DataChineseLanguage> loadDataPinyin() {
//	String[][] idata = quizzChinesePinyin ;
//	List<DataChineseLanguage> data = new ArrayList<DataChineseLanguage>();
//	for (int i = 0 ; idata != null && i < idata.length ; i++) {
//		DataChineseLanguage dat = new DataChineseLanguage(idata[i][0]);
//		data.add(dat);
//		List<String> reponsesTxtPossibles = new ArrayList<String>();
//		String reponsePossibles = idata[i][1] ; 
//		StringTokenizer st = new StringTokenizer(reponsePossibles, ",");
//		
//		while (st.hasMoreTokens()) {
//			reponsesTxtPossibles.add(st.nextToken());
//		}
//		
//		dat.setId(i + "");
//		dat.setReponsesTxtPossibles(reponsesTxtPossibles);
//		dat.setPinyin(idata[i][0]);
//		dat.setIdTypeQuizz(Integer.parseInt(idata[i][3]));
//		dat.setNumQuizz(idata[i][4]);
//		dat.setNote(2);
//	}
//	return data ;
//}



//public static List<DataChineseLanguage> loadData() {
//	return loadData(chineseData) ;
//}
//
//public static int getSound(String pinyin) {
//	for (int i = 0 ; i < chinesePinyin.length ; i++) {
//		if (chinesePinyin[i][0].equals(pinyin) ) return Integer.parseInt(chinesePinyin[i][1]) ; 
//	}
//	return 0 ;
//}

public List<BasicData> getListBasic() {
	List<BasicData> list = new ArrayList<BasicData>(); 
	for (int i = 0 ; i < basicDatas.length ; i++ ) {
		BasicData bd = new BasicData(i,"0", "zÃ©ro","0", "yi",R.raw.ma1,R.raw.ma1  );
		list.add(bd);
	}
	return list ;
}

private static String[][] basicDatas = 
{
	//{"lÄ�",String.valueOf(R.raw.la1)}
} ;



public static String[][] quizzChinesePinyin = 
{
	{"lÇŽ","lÄ�,lÃ¡,lÇŽ,lÃ "		,"1","1","1"}
	
} ;


private static String[][] chineseData = 
{
	{"è¡Œ","???","ligne","1","","","","","","","","1","","",String.valueOf(0)}	
};



}